﻿// <copyright file="Attack.cs" company="Ecole Normale Supérieure">
// Released under GPLv2
// </copyright>
// <summary>Contains the attack class.</summary>

namespace Sqwarea.Persistence
{
    using System;
    using System.Drawing;
    using System.Runtime.Serialization;

    /// <summary>
    /// This class represents an attack (i.e. a movement of troops from the king square to another square).
    /// </summary>
    [DataContract]
    public class Attack 
    {
        /// <summary>
        /// Gets or sets the id of the sender (a king) of this attack.
        /// </summary>
        [DataMember]
        public long SenderId { get; set; }

        /// <summary>
        /// Gets or sets the destination of this attack.
        /// </summary>
        [DataMember]
        public Point Destination { get; set; }

        /// <summary>
        /// Gets or sets the number of troops.
        /// </summary>
        [DataMember]
        public int TroopsNumber { get; set; }

        /// <summary>
        /// Gets or sets the arrival date of troops (date of attack).
        /// </summary>
        [DataMember]
        public DateTimeOffset ArrivalDate { get; set; }
    }
}
